/* Copyright 2018 JDCLOUD.COM

Licensed under the Apache License, Version 2.0 (the "License");
you may not use this file except in compliance with the License.
You may obtain a copy of the License at

http:#www.apache.org/licenses/LICENSE-2.0

Unless required by applicable law or agreed to in writing, software
distributed under the License is distributed on an "AS IS" BASIS,
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
See the License for the specific language governing permissions and
limitations under the License.

镜像仓库认证信息
关于镜像仓库认证信息的相关接口

OpenAPI spec version: v1
Contact: 

NOTE: This class is auto generated by the jdcloud code generator program.
*/

#import <Foundation/Foundation.h>
#import <JDCloudOCSDKNc/NcApiModel.h>


@implementation NcDescribeQuotaRequest
-(id) initWithRegion:(NSString *)regionId
resourceType:(NSString*)resourceType { 
    self.regionId = regionId;
    self.resourceType = resourceType;
    return self;
}

-(id) initWithRegion:(NSString *)regionId
             version:(NSString *)version
resourceType:(NSString*)resourceType { 
    self.regionId = regionId;
    self.version = version;
    self.resourceType = resourceType;
    return self;
}
-(NSMutableDictionary*) dictionary{
    NSMutableDictionary* result = [[NSMutableDictionary alloc] init];
    NSMutableDictionary *superObjectDic = [super dictionary];
    if(superObjectDic && [superObjectDic count]>0)
    {
        [result addEntriesFromDictionary:superObjectDic];
    }
    if([self resourceType])
    {
        [result setValue:[self resourceType] forKey:@"resourceType"];
    }
    return result;
}

-(id) initWithDic:(NSDictionary*)dictionary{
    self.resourceType = [dictionary objectForKey:@"resourceType"];
    return self;
} 

@end
@implementation NcStartContainerRequest
-(id) initWithRegion:(NSString *)regionId
containerId:(NSString*)containerId { 
    self.regionId = regionId;
    self.containerId = containerId;
    return self;
}

-(id) initWithRegion:(NSString *)regionId
             version:(NSString *)version
containerId:(NSString*)containerId { 
    self.regionId = regionId;
    self.version = version;
    self.containerId = containerId;
    return self;
}
-(NSMutableDictionary*) dictionary{
    NSMutableDictionary* result = [[NSMutableDictionary alloc] init];
    NSMutableDictionary *superObjectDic = [super dictionary];
    if(superObjectDic && [superObjectDic count]>0)
    {
        [result addEntriesFromDictionary:superObjectDic];
    }
    if([self containerId])
    {
        [result setValue:[self containerId] forKey:@"containerId"];
    }
    return result;
}

-(id) initWithDic:(NSDictionary*)dictionary{
    self.containerId = [dictionary objectForKey:@"containerId"];
    return self;
} 

@end
@implementation NcDeleteContainerRequest
-(id) initWithRegion:(NSString *)regionId
containerId:(NSString*)containerId { 
    self.regionId = regionId;
    self.containerId = containerId;
    return self;
}

-(id) initWithRegion:(NSString *)regionId
             version:(NSString *)version
containerId:(NSString*)containerId { 
    self.regionId = regionId;
    self.version = version;
    self.containerId = containerId;
    return self;
}
-(NSMutableDictionary*) dictionary{
    NSMutableDictionary* result = [[NSMutableDictionary alloc] init];
    NSMutableDictionary *superObjectDic = [super dictionary];
    if(superObjectDic && [superObjectDic count]>0)
    {
        [result addEntriesFromDictionary:superObjectDic];
    }
    if([self containerId])
    {
        [result setValue:[self containerId] forKey:@"containerId"];
    }
    return result;
}

-(id) initWithDic:(NSDictionary*)dictionary{
    self.containerId = [dictionary objectForKey:@"containerId"];
    return self;
} 

@end
@implementation NcAssociateElasticIpRequest
-(id) initWithRegion:(NSString *)regionId
elasticIpId:(NSString*)elasticIpId
containerId:(NSString*)containerId { 
    self.regionId = regionId;
    self.elasticIpId = elasticIpId;
    self.containerId = containerId;
    return self;
}

-(id) initWithRegion:(NSString *)regionId
             version:(NSString *)version
elasticIpId:(NSString*)elasticIpId
containerId:(NSString*)containerId { 
    self.regionId = regionId;
    self.version = version;
    self.elasticIpId = elasticIpId;
    self.containerId = containerId;
    return self;
}
-(NSMutableDictionary*) dictionary{
    NSMutableDictionary* result = [[NSMutableDictionary alloc] init];
    NSMutableDictionary *superObjectDic = [super dictionary];
    if(superObjectDic && [superObjectDic count]>0)
    {
        [result addEntriesFromDictionary:superObjectDic];
    }
    if([self elasticIpId])
    {
        [result setValue:[self elasticIpId] forKey:@"elasticIpId"];
    }
    if([self containerId])
    {
        [result setValue:[self containerId] forKey:@"containerId"];
    }
    return result;
}

-(id) initWithDic:(NSDictionary*)dictionary{
    self.elasticIpId = [dictionary objectForKey:@"elasticIpId"];
    self.containerId = [dictionary objectForKey:@"containerId"];
    return self;
} 

@end
@implementation NcDescribeContainerRequest
-(id) initWithRegion:(NSString *)regionId
containerId:(NSString*)containerId { 
    self.regionId = regionId;
    self.containerId = containerId;
    return self;
}

-(id) initWithRegion:(NSString *)regionId
             version:(NSString *)version
containerId:(NSString*)containerId { 
    self.regionId = regionId;
    self.version = version;
    self.containerId = containerId;
    return self;
}
-(NSMutableDictionary*) dictionary{
    NSMutableDictionary* result = [[NSMutableDictionary alloc] init];
    NSMutableDictionary *superObjectDic = [super dictionary];
    if(superObjectDic && [superObjectDic count]>0)
    {
        [result addEntriesFromDictionary:superObjectDic];
    }
    if([self containerId])
    {
        [result setValue:[self containerId] forKey:@"containerId"];
    }
    return result;
}

-(id) initWithDic:(NSDictionary*)dictionary{
    self.containerId = [dictionary objectForKey:@"containerId"];
    return self;
} 

@end
@implementation NcCreateContainersResult
-(id) initWithContainerIds:(NSArray<NSString*>*) containerIds { 
    self.containerIds = containerIds;               
    return self;
}
-(NSMutableDictionary*) dictionary{
    NSMutableDictionary* result = [[NSMutableDictionary alloc] init];
    if([self containerIds])
    {
        [result setValue:[self containerIds] forKey:@"containerIds"];
    }
    return result;
}

-(id) initWithDic:(NSDictionary*)dictionary{
    self.containerIds = [dictionary objectForKey:@"containerIds"];
    return self;
} 

@end
@implementation NcDisassociateElasticIpRequest
-(id) initWithRegion:(NSString *)regionId
elasticIpId:(NSString*)elasticIpId
containerId:(NSString*)containerId { 
    self.regionId = regionId;
    self.elasticIpId = elasticIpId;
    self.containerId = containerId;
    return self;
}

-(id) initWithRegion:(NSString *)regionId
             version:(NSString *)version
elasticIpId:(NSString*)elasticIpId
containerId:(NSString*)containerId { 
    self.regionId = regionId;
    self.version = version;
    self.elasticIpId = elasticIpId;
    self.containerId = containerId;
    return self;
}
-(NSMutableDictionary*) dictionary{
    NSMutableDictionary* result = [[NSMutableDictionary alloc] init];
    NSMutableDictionary *superObjectDic = [super dictionary];
    if(superObjectDic && [superObjectDic count]>0)
    {
        [result addEntriesFromDictionary:superObjectDic];
    }
    if([self elasticIpId])
    {
        [result setValue:[self elasticIpId] forKey:@"elasticIpId"];
    }
    if([self containerId])
    {
        [result setValue:[self containerId] forKey:@"containerId"];
    }
    return result;
}

-(id) initWithDic:(NSDictionary*)dictionary{
    self.elasticIpId = [dictionary objectForKey:@"elasticIpId"];
    self.containerId = [dictionary objectForKey:@"containerId"];
    return self;
} 

@end
@implementation NcModifyContainerAttributeRequest
-(id) initWithRegion:(NSString *)regionId
name:(NSString*)name
descriptionValue:(NSString*)descriptionValue
containerId:(NSString*)containerId { 
    self.regionId = regionId;
    self.name = name;
    self.descriptionValue = descriptionValue;
    self.containerId = containerId;
    return self;
}

-(id) initWithRegion:(NSString *)regionId
             version:(NSString *)version
name:(NSString*)name
descriptionValue:(NSString*)descriptionValue
containerId:(NSString*)containerId { 
    self.regionId = regionId;
    self.version = version;
    self.name = name;
    self.descriptionValue = descriptionValue;
    self.containerId = containerId;
    return self;
}
-(NSMutableDictionary*) dictionary{
    NSMutableDictionary* result = [[NSMutableDictionary alloc] init];
    NSMutableDictionary *superObjectDic = [super dictionary];
    if(superObjectDic && [superObjectDic count]>0)
    {
        [result addEntriesFromDictionary:superObjectDic];
    }
    if([self name])
    {
        [result setValue:[self name] forKey:@"name"];
    }
    if([self descriptionValue])
    {
        [result setValue:[self descriptionValue] forKey:@"description"];
    }
    if([self containerId])
    {
        [result setValue:[self containerId] forKey:@"containerId"];
    }
    return result;
}

-(id) initWithDic:(NSDictionary*)dictionary{
    self.name = [dictionary objectForKey:@"name"];
    self.descriptionValue = [dictionary objectForKey:@"description"];
    self.containerId = [dictionary objectForKey:@"containerId"];
    return self;
} 

@end
@implementation NcGetLogsRequest
-(id) initWithRegion:(NSString *)regionId
tailLines:(NSNumber*)tailLines
sinceSeconds:(NSNumber*)sinceSeconds
limitBytes:(NSNumber*)limitBytes
containerId:(NSString*)containerId { 
    self.regionId = regionId;
    self.tailLines = tailLines;
    self.sinceSeconds = sinceSeconds;
    self.limitBytes = limitBytes;
    self.containerId = containerId;
    return self;
}

-(id) initWithRegion:(NSString *)regionId
             version:(NSString *)version
tailLines:(NSNumber*)tailLines
sinceSeconds:(NSNumber*)sinceSeconds
limitBytes:(NSNumber*)limitBytes
containerId:(NSString*)containerId { 
    self.regionId = regionId;
    self.version = version;
    self.tailLines = tailLines;
    self.sinceSeconds = sinceSeconds;
    self.limitBytes = limitBytes;
    self.containerId = containerId;
    return self;
}
-(NSMutableDictionary*) dictionary{
    NSMutableDictionary* result = [[NSMutableDictionary alloc] init];
    NSMutableDictionary *superObjectDic = [super dictionary];
    if(superObjectDic && [superObjectDic count]>0)
    {
        [result addEntriesFromDictionary:superObjectDic];
    }
    if([self tailLines])
    {
        [result setValue:[self tailLines] forKey:@"tailLines"];
    }
    if([self sinceSeconds])
    {
        [result setValue:[self sinceSeconds] forKey:@"sinceSeconds"];
    }
    if([self limitBytes])
    {
        [result setValue:[self limitBytes] forKey:@"limitBytes"];
    }
    if([self containerId])
    {
        [result setValue:[self containerId] forKey:@"containerId"];
    }
    return result;
}

-(id) initWithDic:(NSDictionary*)dictionary{
    self.tailLines = [dictionary objectForKey:@"tailLines"];
    self.sinceSeconds = [dictionary objectForKey:@"sinceSeconds"];
    self.limitBytes = [dictionary objectForKey:@"limitBytes"];
    self.containerId = [dictionary objectForKey:@"containerId"];
    return self;
} 

@end
@implementation NcStopContainerRequest
-(id) initWithRegion:(NSString *)regionId
containerId:(NSString*)containerId { 
    self.regionId = regionId;
    self.containerId = containerId;
    return self;
}

-(id) initWithRegion:(NSString *)regionId
             version:(NSString *)version
containerId:(NSString*)containerId { 
    self.regionId = regionId;
    self.version = version;
    self.containerId = containerId;
    return self;
}
-(NSMutableDictionary*) dictionary{
    NSMutableDictionary* result = [[NSMutableDictionary alloc] init];
    NSMutableDictionary *superObjectDic = [super dictionary];
    if(superObjectDic && [superObjectDic count]>0)
    {
        [result addEntriesFromDictionary:superObjectDic];
    }
    if([self containerId])
    {
        [result setValue:[self containerId] forKey:@"containerId"];
    }
    return result;
}

-(id) initWithDic:(NSDictionary*)dictionary{
    self.containerId = [dictionary objectForKey:@"containerId"];
    return self;
} 

@end
@implementation NcDeleteSecretRequest
-(id) initWithRegion:(NSString *)regionId
name:(NSString*)name { 
    self.regionId = regionId;
    self.name = name;
    return self;
}

-(id) initWithRegion:(NSString *)regionId
             version:(NSString *)version
name:(NSString*)name { 
    self.regionId = regionId;
    self.version = version;
    self.name = name;
    return self;
}
-(NSMutableDictionary*) dictionary{
    NSMutableDictionary* result = [[NSMutableDictionary alloc] init];
    NSMutableDictionary *superObjectDic = [super dictionary];
    if(superObjectDic && [superObjectDic count]>0)
    {
        [result addEntriesFromDictionary:superObjectDic];
    }
    if([self name])
    {
        [result setValue:[self name] forKey:@"name"];
    }
    return result;
}

-(id) initWithDic:(NSDictionary*)dictionary{
    self.name = [dictionary objectForKey:@"name"];
    return self;
} 

@end
@implementation NcCreateSecretResult
-(id) initWithSecretName:(NSString*) secretName { 
    self.secretName = secretName;               
    return self;
}
-(NSMutableDictionary*) dictionary{
    NSMutableDictionary* result = [[NSMutableDictionary alloc] init];
    if([self secretName])
    {
        [result setValue:[self secretName] forKey:@"secretName"];
    }
    return result;
}

-(id) initWithDic:(NSDictionary*)dictionary{
    self.secretName = [dictionary objectForKey:@"secretName"];
    return self;
} 

@end
@implementation NcDescribeSecretRequest
-(id) initWithRegion:(NSString *)regionId
name:(NSString*)name { 
    self.regionId = regionId;
    self.name = name;
    return self;
}

-(id) initWithRegion:(NSString *)regionId
             version:(NSString *)version
name:(NSString*)name { 
    self.regionId = regionId;
    self.version = version;
    self.name = name;
    return self;
}
-(NSMutableDictionary*) dictionary{
    NSMutableDictionary* result = [[NSMutableDictionary alloc] init];
    NSMutableDictionary *superObjectDic = [super dictionary];
    if(superObjectDic && [superObjectDic count]>0)
    {
        [result addEntriesFromDictionary:superObjectDic];
    }
    if([self name])
    {
        [result setValue:[self name] forKey:@"name"];
    }
    return result;
}

-(id) initWithDic:(NSDictionary*)dictionary{
    self.name = [dictionary objectForKey:@"name"];
    return self;
} 

@end
@implementation NcDescribeQuotaResult
-(id) initWithQuota:(NcQuota*) quota { 
    self.quota = quota;               
    return self;
}
-(NSMutableDictionary*) dictionary{
    NSMutableDictionary* result = [[NSMutableDictionary alloc] init];
    if([self quota])
    {
        [result setValue:[[self quota] dictionary]forKey:@"quota"];
    }
    return result;
}

-(id) initWithDic:(NSDictionary*)dictionary{
    self.quota = [[NcQuota alloc]initWithDic:[dictionary objectForKey:@"quota"]];
    return self;
} 

@end
  
@implementation NcDescribeQuotaResponse
-(NSMutableDictionary*) dictionary
{
    NSMutableDictionary* result = [[NSMutableDictionary alloc] init]; 
    if([self requestId])
    {
        [result setValue:[self requestId] forKey:@"requestId"];
    } 
    if([self result])
    {
        
        [result setValue:[[self result] dictionary] forKey:@"result"];
    }
    if([self error])
    {
        
        [result setValue:[[self error] dictionary] forKey:@"error"];
    }
    return result;
}

-(id) initWithDic:(NSDictionary*)dictionary
{
    
    self.requestId = [dictionary objectForKey:@"requestId"];
NcDescribeQuotaResult* result = [[NcDescribeQuotaResult alloc]initWithDic:[dictionary objectForKey:@"result"]];
    self.result = result;
    ServiceError* error = [[ServiceError alloc]initWithDic:[dictionary objectForKey:@"error"]];
    self.error = error;
    return self;
}

-(id) initWithRequestId:(NSString*) requestId
                  error:(ServiceError*) error
                 result:(NcDescribeQuotaResult*) result
{
    self.error = error;
    self.result =result;
    self.requestId = requestId;
    return self;
}

@end
@implementation NcDescribeContainersResult
-(id) initWithContainers:(NSArray<Container*>*) containers
        totalCount:(NSNumber*)totalCount { 
    self.containers = containers;               
    self.totalCount = totalCount;               
    return self;
}
-(NSMutableDictionary*) dictionary{
    NSMutableDictionary* result = [[NSMutableDictionary alloc] init];
    if([self containers])
    {
            NSMutableArray<NSDictionary*>* arrayDic  = [[NSMutableArray alloc] init];
            for (int i =0 ; i< [[self containers] count]; i++) {
            Container* item = [[self containers] objectAtIndex:i];
            [arrayDic addObject:[item dictionary]];
        }
        [result setValue:arrayDic forKey:@"containers"];
    }
    if([self totalCount])
    {
        [result setValue:[self totalCount] forKey:@"totalCount"];
    }
    return result;
}

-(id) initWithDic:(NSDictionary*)dictionary{
    NSArray* containersArray = [dictionary objectForKey:@"containers"];
    if(containersArray&&![containersArray isKindOfClass:[NSNull class]])
    {
        NSMutableArray* propertyArray = [[NSMutableArray alloc]init];
        for(int i = 0 ; i< [containersArray count];i++)
        {
        Container* item = [[Container alloc]initWithDic:[containersArray objectAtIndex:i]];
            if(item)
            {
            [propertyArray addObject:item];
            }
        }
        self.containers = propertyArray;
    }
    self.totalCount = [dictionary objectForKey:@"totalCount"];
    return self;
} 

@end
@implementation NcStartContainerResult
-(NSMutableDictionary*) dictionary{
    NSMutableDictionary* result = [[NSMutableDictionary alloc] init];
    return result;
}

-(id) initWithDic:(NSDictionary*)dictionary{
    return self;
} 

@end
  
@implementation NcStartContainerResponse
-(NSMutableDictionary*) dictionary
{
    NSMutableDictionary* result = [[NSMutableDictionary alloc] init]; 
    if([self requestId])
    {
        [result setValue:[self requestId] forKey:@"requestId"];
    } 
    if([self result])
    {
        
        [result setValue:[[self result] dictionary] forKey:@"result"];
    }
    if([self error])
    {
        
        [result setValue:[[self error] dictionary] forKey:@"error"];
    }
    return result;
}

-(id) initWithDic:(NSDictionary*)dictionary
{
    
    self.requestId = [dictionary objectForKey:@"requestId"];
NcStartContainerResult* result = [[NcStartContainerResult alloc]initWithDic:[dictionary objectForKey:@"result"]];
    self.result = result;
    ServiceError* error = [[ServiceError alloc]initWithDic:[dictionary objectForKey:@"error"]];
    self.error = error;
    return self;
}

-(id) initWithRequestId:(NSString*) requestId
                  error:(ServiceError*) error
                 result:(NcStartContainerResult*) result
{
    self.error = error;
    self.result =result;
    self.requestId = requestId;
    return self;
}

@end
@implementation NcDescribeContainersRequest
-(id) initWithRegion:(NSString *)regionId
pageNumber:(NSNumber*)pageNumber
pageSize:(NSNumber*)pageSize
filters:(NSArray<Filter*>*)filters { 
    self.regionId = regionId;
    self.pageNumber = pageNumber;
    self.pageSize = pageSize;
    self.filters = filters;
    return self;
}

-(id) initWithRegion:(NSString *)regionId
             version:(NSString *)version
pageNumber:(NSNumber*)pageNumber
pageSize:(NSNumber*)pageSize
filters:(NSArray<Filter*>*)filters { 
    self.regionId = regionId;
    self.version = version;
    self.pageNumber = pageNumber;
    self.pageSize = pageSize;
    self.filters = filters;
    return self;
}
-(NSMutableDictionary*) dictionary{
    NSMutableDictionary* result = [[NSMutableDictionary alloc] init];
    NSMutableDictionary *superObjectDic = [super dictionary];
    if(superObjectDic && [superObjectDic count]>0)
    {
        [result addEntriesFromDictionary:superObjectDic];
    }
    if([self pageNumber])
    {
        [result setValue:[self pageNumber] forKey:@"pageNumber"];
    }
    if([self pageSize])
    {
        [result setValue:[self pageSize] forKey:@"pageSize"];
    }
    if([self filters])
    {
            NSMutableArray<NSDictionary*>* arrayDic  = [[NSMutableArray alloc] init];
            for (int i =0 ; i< [[self filters] count]; i++) {
            Filter* item = [[self filters] objectAtIndex:i];
            [arrayDic addObject:[item dictionary]];
        }
        [result setValue:arrayDic forKey:@"filters"];
    }
    return result;
}

-(id) initWithDic:(NSDictionary*)dictionary{
    self.pageNumber = [dictionary objectForKey:@"pageNumber"];
    self.pageSize = [dictionary objectForKey:@"pageSize"];
    NSArray* filtersArray = [dictionary objectForKey:@"filters"];
    if(filtersArray&&![filtersArray isKindOfClass:[NSNull class]])
    {
        NSMutableArray* propertyArray = [[NSMutableArray alloc]init];
        for(int i = 0 ; i< [filtersArray count];i++)
        {
        Filter* item = [[Filter alloc]initWithDic:[filtersArray objectAtIndex:i]];
            if(item)
            {
            [propertyArray addObject:item];
            }
        }
        self.filters = propertyArray;
    }
    return self;
} 

@end
@implementation NcDescribeContainerResult
-(id) initWithContainer:(Container*) container { 
    self.container = container;               
    return self;
}
-(NSMutableDictionary*) dictionary{
    NSMutableDictionary* result = [[NSMutableDictionary alloc] init];
    if([self container])
    {
        [result setValue:[[self container] dictionary]forKey:@"container"];
    }
    return result;
}

-(id) initWithDic:(NSDictionary*)dictionary{
    self.container = [[Container alloc]initWithDic:[dictionary objectForKey:@"container"]];
    return self;
} 

@end
@implementation NcDeleteContainerResult
-(NSMutableDictionary*) dictionary{
    NSMutableDictionary* result = [[NSMutableDictionary alloc] init];
    return result;
}

-(id) initWithDic:(NSDictionary*)dictionary{
    return self;
} 

@end
@implementation NcStopContainerResult
-(NSMutableDictionary*) dictionary{
    NSMutableDictionary* result = [[NSMutableDictionary alloc] init];
    return result;
}

-(id) initWithDic:(NSDictionary*)dictionary{
    return self;
} 

@end
  
@implementation NcDeleteContainerResponse
-(NSMutableDictionary*) dictionary
{
    NSMutableDictionary* result = [[NSMutableDictionary alloc] init]; 
    if([self requestId])
    {
        [result setValue:[self requestId] forKey:@"requestId"];
    } 
    if([self result])
    {
        
        [result setValue:[[self result] dictionary] forKey:@"result"];
    }
    if([self error])
    {
        
        [result setValue:[[self error] dictionary] forKey:@"error"];
    }
    return result;
}

-(id) initWithDic:(NSDictionary*)dictionary
{
    
    self.requestId = [dictionary objectForKey:@"requestId"];
NcDeleteContainerResult* result = [[NcDeleteContainerResult alloc]initWithDic:[dictionary objectForKey:@"result"]];
    self.result = result;
    ServiceError* error = [[ServiceError alloc]initWithDic:[dictionary objectForKey:@"error"]];
    self.error = error;
    return self;
}

-(id) initWithRequestId:(NSString*) requestId
                  error:(ServiceError*) error
                 result:(NcDeleteContainerResult*) result
{
    self.error = error;
    self.result =result;
    self.requestId = requestId;
    return self;
}

@end
@implementation NcDisassociateElasticIpResult
-(NSMutableDictionary*) dictionary{
    NSMutableDictionary* result = [[NSMutableDictionary alloc] init];
    return result;
}

-(id) initWithDic:(NSDictionary*)dictionary{
    return self;
} 

@end
  
@implementation NcDescribeContainerResponse
-(NSMutableDictionary*) dictionary
{
    NSMutableDictionary* result = [[NSMutableDictionary alloc] init]; 
    if([self requestId])
    {
        [result setValue:[self requestId] forKey:@"requestId"];
    } 
    if([self result])
    {
        
        [result setValue:[[self result] dictionary] forKey:@"result"];
    }
    if([self error])
    {
        
        [result setValue:[[self error] dictionary] forKey:@"error"];
    }
    return result;
}

-(id) initWithDic:(NSDictionary*)dictionary
{
    
    self.requestId = [dictionary objectForKey:@"requestId"];
NcDescribeContainerResult* result = [[NcDescribeContainerResult alloc]initWithDic:[dictionary objectForKey:@"result"]];
    self.result = result;
    ServiceError* error = [[ServiceError alloc]initWithDic:[dictionary objectForKey:@"error"]];
    self.error = error;
    return self;
}

-(id) initWithRequestId:(NSString*) requestId
                  error:(ServiceError*) error
                 result:(NcDescribeContainerResult*) result
{
    self.error = error;
    self.result =result;
    self.requestId = requestId;
    return self;
}

@end
  
@implementation NcStopContainerResponse
-(NSMutableDictionary*) dictionary
{
    NSMutableDictionary* result = [[NSMutableDictionary alloc] init]; 
    if([self requestId])
    {
        [result setValue:[self requestId] forKey:@"requestId"];
    } 
    if([self result])
    {
        
        [result setValue:[[self result] dictionary] forKey:@"result"];
    }
    if([self error])
    {
        
        [result setValue:[[self error] dictionary] forKey:@"error"];
    }
    return result;
}

-(id) initWithDic:(NSDictionary*)dictionary
{
    
    self.requestId = [dictionary objectForKey:@"requestId"];
NcStopContainerResult* result = [[NcStopContainerResult alloc]initWithDic:[dictionary objectForKey:@"result"]];
    self.result = result;
    ServiceError* error = [[ServiceError alloc]initWithDic:[dictionary objectForKey:@"error"]];
    self.error = error;
    return self;
}

-(id) initWithRequestId:(NSString*) requestId
                  error:(ServiceError*) error
                 result:(NcStopContainerResult*) result
{
    self.error = error;
    self.result =result;
    self.requestId = requestId;
    return self;
}

@end
@implementation NcAssociateElasticIpResult
-(NSMutableDictionary*) dictionary{
    NSMutableDictionary* result = [[NSMutableDictionary alloc] init];
    return result;
}

-(id) initWithDic:(NSDictionary*)dictionary{
    return self;
} 

@end
  
@implementation NcAssociateElasticIpResponse
-(NSMutableDictionary*) dictionary
{
    NSMutableDictionary* result = [[NSMutableDictionary alloc] init]; 
    if([self requestId])
    {
        [result setValue:[self requestId] forKey:@"requestId"];
    } 
    if([self result])
    {
        
        [result setValue:[[self result] dictionary] forKey:@"result"];
    }
    if([self error])
    {
        
        [result setValue:[[self error] dictionary] forKey:@"error"];
    }
    return result;
}

-(id) initWithDic:(NSDictionary*)dictionary
{
    
    self.requestId = [dictionary objectForKey:@"requestId"];
NcAssociateElasticIpResult* result = [[NcAssociateElasticIpResult alloc]initWithDic:[dictionary objectForKey:@"result"]];
    self.result = result;
    ServiceError* error = [[ServiceError alloc]initWithDic:[dictionary objectForKey:@"error"]];
    self.error = error;
    return self;
}

-(id) initWithRequestId:(NSString*) requestId
                  error:(ServiceError*) error
                 result:(NcAssociateElasticIpResult*) result
{
    self.error = error;
    self.result =result;
    self.requestId = requestId;
    return self;
}

@end
@implementation NcModifyContainerAttributeResult
-(NSMutableDictionary*) dictionary{
    NSMutableDictionary* result = [[NSMutableDictionary alloc] init];
    return result;
}

-(id) initWithDic:(NSDictionary*)dictionary{
    return self;
} 

@end
  
@implementation NcCreateContainersResponse
-(NSMutableDictionary*) dictionary
{
    NSMutableDictionary* result = [[NSMutableDictionary alloc] init]; 
    if([self requestId])
    {
        [result setValue:[self requestId] forKey:@"requestId"];
    } 
    if([self result])
    {
        
        [result setValue:[[self result] dictionary] forKey:@"result"];
    }
    if([self error])
    {
        
        [result setValue:[[self error] dictionary] forKey:@"error"];
    }
    return result;
}

-(id) initWithDic:(NSDictionary*)dictionary
{
    
    self.requestId = [dictionary objectForKey:@"requestId"];
NcCreateContainersResult* result = [[NcCreateContainersResult alloc]initWithDic:[dictionary objectForKey:@"result"]];
    self.result = result;
    ServiceError* error = [[ServiceError alloc]initWithDic:[dictionary objectForKey:@"error"]];
    self.error = error;
    return self;
}

-(id) initWithRequestId:(NSString*) requestId
                  error:(ServiceError*) error
                 result:(NcCreateContainersResult*) result
{
    self.error = error;
    self.result =result;
    self.requestId = requestId;
    return self;
}

@end
@implementation NcGetLogsResult
-(id) initWithLogs:(Logs*) logs { 
    self.logs = logs;               
    return self;
}
-(NSMutableDictionary*) dictionary{
    NSMutableDictionary* result = [[NSMutableDictionary alloc] init];
    if([self logs])
    {
        [result setValue:[[self logs] dictionary]forKey:@"logs"];
    }
    return result;
}

-(id) initWithDic:(NSDictionary*)dictionary{
    self.logs = [[Logs alloc]initWithDic:[dictionary objectForKey:@"logs"]];
    return self;
} 

@end
@implementation NcCreateContainersRequest
-(id) initWithRegion:(NSString *)regionId
containerSpec:(ContainerSpec*)containerSpec
maxCount:(NSNumber*)maxCount { 
    self.regionId = regionId;
    self.containerSpec = containerSpec;
    self.maxCount = maxCount;
    return self;
}

-(id) initWithRegion:(NSString *)regionId
             version:(NSString *)version
containerSpec:(ContainerSpec*)containerSpec
maxCount:(NSNumber*)maxCount { 
    self.regionId = regionId;
    self.version = version;
    self.containerSpec = containerSpec;
    self.maxCount = maxCount;
    return self;
}
-(NSMutableDictionary*) dictionary{
    NSMutableDictionary* result = [[NSMutableDictionary alloc] init];
    NSMutableDictionary *superObjectDic = [super dictionary];
    if(superObjectDic && [superObjectDic count]>0)
    {
        [result addEntriesFromDictionary:superObjectDic];
    }
    if([self containerSpec])
    {
        [result setValue:[[self containerSpec] dictionary]forKey:@"containerSpec"];
    }
    if([self maxCount])
    {
        [result setValue:[self maxCount] forKey:@"maxCount"];
    }
    return result;
}

-(id) initWithDic:(NSDictionary*)dictionary{
    self.containerSpec = [[ContainerSpec alloc]initWithDic:[dictionary objectForKey:@"containerSpec"]];
    self.maxCount = [dictionary objectForKey:@"maxCount"];
    return self;
} 

@end
  
@implementation NcGetLogsResponse
-(NSMutableDictionary*) dictionary
{
    NSMutableDictionary* result = [[NSMutableDictionary alloc] init]; 
    if([self requestId])
    {
        [result setValue:[self requestId] forKey:@"requestId"];
    } 
    if([self result])
    {
        
        [result setValue:[[self result] dictionary] forKey:@"result"];
    }
    if([self error])
    {
        
        [result setValue:[[self error] dictionary] forKey:@"error"];
    }
    return result;
}

-(id) initWithDic:(NSDictionary*)dictionary
{
    
    self.requestId = [dictionary objectForKey:@"requestId"];
NcGetLogsResult* result = [[NcGetLogsResult alloc]initWithDic:[dictionary objectForKey:@"result"]];
    self.result = result;
    ServiceError* error = [[ServiceError alloc]initWithDic:[dictionary objectForKey:@"error"]];
    self.error = error;
    return self;
}

-(id) initWithRequestId:(NSString*) requestId
                  error:(ServiceError*) error
                 result:(NcGetLogsResult*) result
{
    self.error = error;
    self.result =result;
    self.requestId = requestId;
    return self;
}

@end
  
@implementation NcModifyContainerAttributeResponse
-(NSMutableDictionary*) dictionary
{
    NSMutableDictionary* result = [[NSMutableDictionary alloc] init]; 
    if([self requestId])
    {
        [result setValue:[self requestId] forKey:@"requestId"];
    } 
    if([self result])
    {
        
        [result setValue:[[self result] dictionary] forKey:@"result"];
    }
    if([self error])
    {
        
        [result setValue:[[self error] dictionary] forKey:@"error"];
    }
    return result;
}

-(id) initWithDic:(NSDictionary*)dictionary
{
    
    self.requestId = [dictionary objectForKey:@"requestId"];
NcModifyContainerAttributeResult* result = [[NcModifyContainerAttributeResult alloc]initWithDic:[dictionary objectForKey:@"result"]];
    self.result = result;
    ServiceError* error = [[ServiceError alloc]initWithDic:[dictionary objectForKey:@"error"]];
    self.error = error;
    return self;
}

-(id) initWithRequestId:(NSString*) requestId
                  error:(ServiceError*) error
                 result:(NcModifyContainerAttributeResult*) result
{
    self.error = error;
    self.result =result;
    self.requestId = requestId;
    return self;
}

@end
  
@implementation NcDisassociateElasticIpResponse
-(NSMutableDictionary*) dictionary
{
    NSMutableDictionary* result = [[NSMutableDictionary alloc] init]; 
    if([self requestId])
    {
        [result setValue:[self requestId] forKey:@"requestId"];
    } 
    if([self result])
    {
        
        [result setValue:[[self result] dictionary] forKey:@"result"];
    }
    if([self error])
    {
        
        [result setValue:[[self error] dictionary] forKey:@"error"];
    }
    return result;
}

-(id) initWithDic:(NSDictionary*)dictionary
{
    
    self.requestId = [dictionary objectForKey:@"requestId"];
NcDisassociateElasticIpResult* result = [[NcDisassociateElasticIpResult alloc]initWithDic:[dictionary objectForKey:@"result"]];
    self.result = result;
    ServiceError* error = [[ServiceError alloc]initWithDic:[dictionary objectForKey:@"error"]];
    self.error = error;
    return self;
}

-(id) initWithRequestId:(NSString*) requestId
                  error:(ServiceError*) error
                 result:(NcDisassociateElasticIpResult*) result
{
    self.error = error;
    self.result =result;
    self.requestId = requestId;
    return self;
}

@end
  
@implementation NcDescribeContainersResponse
-(NSMutableDictionary*) dictionary
{
    NSMutableDictionary* result = [[NSMutableDictionary alloc] init]; 
    if([self requestId])
    {
        [result setValue:[self requestId] forKey:@"requestId"];
    } 
    if([self result])
    {
        
        [result setValue:[[self result] dictionary] forKey:@"result"];
    }
    if([self error])
    {
        
        [result setValue:[[self error] dictionary] forKey:@"error"];
    }
    return result;
}

-(id) initWithDic:(NSDictionary*)dictionary
{
    
    self.requestId = [dictionary objectForKey:@"requestId"];
NcDescribeContainersResult* result = [[NcDescribeContainersResult alloc]initWithDic:[dictionary objectForKey:@"result"]];
    self.result = result;
    ServiceError* error = [[ServiceError alloc]initWithDic:[dictionary objectForKey:@"error"]];
    self.error = error;
    return self;
}

-(id) initWithRequestId:(NSString*) requestId
                  error:(ServiceError*) error
                 result:(NcDescribeContainersResult*) result
{
    self.error = error;
    self.result =result;
    self.requestId = requestId;
    return self;
}

@end
@implementation NcCreateSecretRequest
-(id) initWithRegion:(NSString *)regionId
name:(NSString*)name
secretType:(NSString*)secretType
data:(DockerRegistryData*)data { 
    self.regionId = regionId;
    self.name = name;
    self.secretType = secretType;
    self.data = data;
    return self;
}

-(id) initWithRegion:(NSString *)regionId
             version:(NSString *)version
name:(NSString*)name
secretType:(NSString*)secretType
data:(DockerRegistryData*)data { 
    self.regionId = regionId;
    self.version = version;
    self.name = name;
    self.secretType = secretType;
    self.data = data;
    return self;
}
-(NSMutableDictionary*) dictionary{
    NSMutableDictionary* result = [[NSMutableDictionary alloc] init];
    NSMutableDictionary *superObjectDic = [super dictionary];
    if(superObjectDic && [superObjectDic count]>0)
    {
        [result addEntriesFromDictionary:superObjectDic];
    }
    if([self name])
    {
        [result setValue:[self name] forKey:@"name"];
    }
    if([self secretType])
    {
        [result setValue:[self secretType] forKey:@"secretType"];
    }
    if([self data])
    {
        [result setValue:[[self data] dictionary]forKey:@"data"];
    }
    return result;
}

-(id) initWithDic:(NSDictionary*)dictionary{
    self.name = [dictionary objectForKey:@"name"];
    self.secretType = [dictionary objectForKey:@"secretType"];
    self.data = [[DockerRegistryData alloc]initWithDic:[dictionary objectForKey:@"data"]];
    return self;
} 

@end
@implementation NcDescribeSecretsResult
-(id) initWithSecrets:(NSArray<Secret*>*) secrets
        totalCount:(NSNumber*)totalCount { 
    self.secrets = secrets;               
    self.totalCount = totalCount;               
    return self;
}
-(NSMutableDictionary*) dictionary{
    NSMutableDictionary* result = [[NSMutableDictionary alloc] init];
    if([self secrets])
    {
            NSMutableArray<NSDictionary*>* arrayDic  = [[NSMutableArray alloc] init];
            for (int i =0 ; i< [[self secrets] count]; i++) {
            Secret* item = [[self secrets] objectAtIndex:i];
            [arrayDic addObject:[item dictionary]];
        }
        [result setValue:arrayDic forKey:@"secrets"];
    }
    if([self totalCount])
    {
        [result setValue:[self totalCount] forKey:@"totalCount"];
    }
    return result;
}

-(id) initWithDic:(NSDictionary*)dictionary{
    NSArray* secretsArray = [dictionary objectForKey:@"secrets"];
    if(secretsArray&&![secretsArray isKindOfClass:[NSNull class]])
    {
        NSMutableArray* propertyArray = [[NSMutableArray alloc]init];
        for(int i = 0 ; i< [secretsArray count];i++)
        {
        Secret* item = [[Secret alloc]initWithDic:[secretsArray objectAtIndex:i]];
            if(item)
            {
            [propertyArray addObject:item];
            }
        }
        self.secrets = propertyArray;
    }
    self.totalCount = [dictionary objectForKey:@"totalCount"];
    return self;
} 

@end
  
@implementation NcDescribeSecretsResponse
-(NSMutableDictionary*) dictionary
{
    NSMutableDictionary* result = [[NSMutableDictionary alloc] init]; 
    if([self requestId])
    {
        [result setValue:[self requestId] forKey:@"requestId"];
    } 
    if([self result])
    {
        
        [result setValue:[[self result] dictionary] forKey:@"result"];
    }
    if([self error])
    {
        
        [result setValue:[[self error] dictionary] forKey:@"error"];
    }
    return result;
}

-(id) initWithDic:(NSDictionary*)dictionary
{
    
    self.requestId = [dictionary objectForKey:@"requestId"];
NcDescribeSecretsResult* result = [[NcDescribeSecretsResult alloc]initWithDic:[dictionary objectForKey:@"result"]];
    self.result = result;
    ServiceError* error = [[ServiceError alloc]initWithDic:[dictionary objectForKey:@"error"]];
    self.error = error;
    return self;
}

-(id) initWithRequestId:(NSString*) requestId
                  error:(ServiceError*) error
                 result:(NcDescribeSecretsResult*) result
{
    self.error = error;
    self.result =result;
    self.requestId = requestId;
    return self;
}

@end
@implementation NcDeleteSecretResult
-(NSMutableDictionary*) dictionary{
    NSMutableDictionary* result = [[NSMutableDictionary alloc] init];
    return result;
}

-(id) initWithDic:(NSDictionary*)dictionary{
    return self;
} 

@end
  
@implementation NcDeleteSecretResponse
-(NSMutableDictionary*) dictionary
{
    NSMutableDictionary* result = [[NSMutableDictionary alloc] init]; 
    if([self requestId])
    {
        [result setValue:[self requestId] forKey:@"requestId"];
    } 
    if([self result])
    {
        
        [result setValue:[[self result] dictionary] forKey:@"result"];
    }
    if([self error])
    {
        
        [result setValue:[[self error] dictionary] forKey:@"error"];
    }
    return result;
}

-(id) initWithDic:(NSDictionary*)dictionary
{
    
    self.requestId = [dictionary objectForKey:@"requestId"];
NcDeleteSecretResult* result = [[NcDeleteSecretResult alloc]initWithDic:[dictionary objectForKey:@"result"]];
    self.result = result;
    ServiceError* error = [[ServiceError alloc]initWithDic:[dictionary objectForKey:@"error"]];
    self.error = error;
    return self;
}

-(id) initWithRequestId:(NSString*) requestId
                  error:(ServiceError*) error
                 result:(NcDeleteSecretResult*) result
{
    self.error = error;
    self.result =result;
    self.requestId = requestId;
    return self;
}

@end
  
@implementation NcCreateSecretResponse
-(NSMutableDictionary*) dictionary
{
    NSMutableDictionary* result = [[NSMutableDictionary alloc] init]; 
    if([self requestId])
    {
        [result setValue:[self requestId] forKey:@"requestId"];
    } 
    if([self result])
    {
        
        [result setValue:[[self result] dictionary] forKey:@"result"];
    }
    if([self error])
    {
        
        [result setValue:[[self error] dictionary] forKey:@"error"];
    }
    return result;
}

-(id) initWithDic:(NSDictionary*)dictionary
{
    
    self.requestId = [dictionary objectForKey:@"requestId"];
NcCreateSecretResult* result = [[NcCreateSecretResult alloc]initWithDic:[dictionary objectForKey:@"result"]];
    self.result = result;
    ServiceError* error = [[ServiceError alloc]initWithDic:[dictionary objectForKey:@"error"]];
    self.error = error;
    return self;
}

-(id) initWithRequestId:(NSString*) requestId
                  error:(ServiceError*) error
                 result:(NcCreateSecretResult*) result
{
    self.error = error;
    self.result =result;
    self.requestId = requestId;
    return self;
}

@end
@implementation NcDescribeSecretResult
-(id) initWithSecret:(Secret*) secret { 
    self.secret = secret;               
    return self;
}
-(NSMutableDictionary*) dictionary{
    NSMutableDictionary* result = [[NSMutableDictionary alloc] init];
    if([self secret])
    {
        [result setValue:[[self secret] dictionary]forKey:@"secret"];
    }
    return result;
}

-(id) initWithDic:(NSDictionary*)dictionary{
    self.secret = [[Secret alloc]initWithDic:[dictionary objectForKey:@"secret"]];
    return self;
} 

@end
@implementation NcDescribeSecretsRequest
-(id) initWithRegion:(NSString *)regionId
pageNumber:(NSNumber*)pageNumber
pageSize:(NSNumber*)pageSize
filters:(NSArray<Filter*>*)filters { 
    self.regionId = regionId;
    self.pageNumber = pageNumber;
    self.pageSize = pageSize;
    self.filters = filters;
    return self;
}

-(id) initWithRegion:(NSString *)regionId
             version:(NSString *)version
pageNumber:(NSNumber*)pageNumber
pageSize:(NSNumber*)pageSize
filters:(NSArray<Filter*>*)filters { 
    self.regionId = regionId;
    self.version = version;
    self.pageNumber = pageNumber;
    self.pageSize = pageSize;
    self.filters = filters;
    return self;
}
-(NSMutableDictionary*) dictionary{
    NSMutableDictionary* result = [[NSMutableDictionary alloc] init];
    NSMutableDictionary *superObjectDic = [super dictionary];
    if(superObjectDic && [superObjectDic count]>0)
    {
        [result addEntriesFromDictionary:superObjectDic];
    }
    if([self pageNumber])
    {
        [result setValue:[self pageNumber] forKey:@"pageNumber"];
    }
    if([self pageSize])
    {
        [result setValue:[self pageSize] forKey:@"pageSize"];
    }
    if([self filters])
    {
            NSMutableArray<NSDictionary*>* arrayDic  = [[NSMutableArray alloc] init];
            for (int i =0 ; i< [[self filters] count]; i++) {
            Filter* item = [[self filters] objectAtIndex:i];
            [arrayDic addObject:[item dictionary]];
        }
        [result setValue:arrayDic forKey:@"filters"];
    }
    return result;
}

-(id) initWithDic:(NSDictionary*)dictionary{
    self.pageNumber = [dictionary objectForKey:@"pageNumber"];
    self.pageSize = [dictionary objectForKey:@"pageSize"];
    NSArray* filtersArray = [dictionary objectForKey:@"filters"];
    if(filtersArray&&![filtersArray isKindOfClass:[NSNull class]])
    {
        NSMutableArray* propertyArray = [[NSMutableArray alloc]init];
        for(int i = 0 ; i< [filtersArray count];i++)
        {
        Filter* item = [[Filter alloc]initWithDic:[filtersArray objectAtIndex:i]];
            if(item)
            {
            [propertyArray addObject:item];
            }
        }
        self.filters = propertyArray;
    }
    return self;
} 

@end
  
@implementation NcDescribeSecretResponse
-(NSMutableDictionary*) dictionary
{
    NSMutableDictionary* result = [[NSMutableDictionary alloc] init]; 
    if([self requestId])
    {
        [result setValue:[self requestId] forKey:@"requestId"];
    } 
    if([self result])
    {
        
        [result setValue:[[self result] dictionary] forKey:@"result"];
    }
    if([self error])
    {
        
        [result setValue:[[self error] dictionary] forKey:@"error"];
    }
    return result;
}

-(id) initWithDic:(NSDictionary*)dictionary
{
    
    self.requestId = [dictionary objectForKey:@"requestId"];
NcDescribeSecretResult* result = [[NcDescribeSecretResult alloc]initWithDic:[dictionary objectForKey:@"result"]];
    self.result = result;
    ServiceError* error = [[ServiceError alloc]initWithDic:[dictionary objectForKey:@"error"]];
    self.error = error;
    return self;
}

-(id) initWithRequestId:(NSString*) requestId
                  error:(ServiceError*) error
                 result:(NcDescribeSecretResult*) result
{
    self.error = error;
    self.result =result;
    self.requestId = requestId;
    return self;
}

@end
 
